﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using App.Models;

namespace App.Controllers
{
    public class TTTGameController : Controller
    {
		public ActionResult Index(int id)
		{
			AppDataContext db = new AppDataContext();

			var instance = (from game in db.Games
						    where game.GameID == id
							select game).SingleOrDefault();

			if (instance != null)
			{
				return View(instance);
			}
		
			return View("NotFound");
		}
	}
}
